Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OutStreams as RAVEN entity #1329

Merged
merged 18 commits into from
Oct 3, 2020
Merged

OutStreams as RAVEN entity #1329

merged 18 commits into from
Oct 3, 2020

Conversation

PaulTalbot-INL
Copy link
Collaborator

@PaulTalbot-INL PaulTalbot-INL commented Oct 2, 2020


Pull Request Description

What issue does this change request address? (Use "#" before the issue to link it, i.e., #42.)

Closes #1328
Addresses #1114, Closes #1325

What are the significant changes in functionality due to this change request?

Restructures OutStreamManager, OutStreamPrint, and OutStreamPlot.

New base class is OutStreamBase, which is a standard RAVEN entity.

New printer is FilePrint, which is accessed through the <Print> option for traditional printing.
New plotter is GeneralPlot, which is accessed through the <Plot> option for traditional plotting.

New entities for OutStreams can inherit from OutStreamBase and be added to the Factory to create new options.

No change to existing input files is needed as a result of these changes.


For Change Control Board: Change Request Review

The following review must be completed by an authorized member of the Change Control Board.

  • 1. Review all computer code.
  • 2. If any changes occur to the input syntax, there must be an accompanying change to the user manual and xsd schema. If the input syntax change deprecates existing input files, a conversion script needs to be added (see Conversion Scripts).
  • 3. Make sure the Python code and commenting standards are respected (camelBack, etc.) - See on the wiki for details.
  • 4. Automated Tests should pass, including run_tests, pylint, manual building and xsd tests. If there are changes to Simulation.py or JobHandler.py the qsub tests must pass.
  • 5. If significant functionality is added, there must be tests added to check this. Tests should cover all possible options. Multiple short tests are preferred over one large test. If new development on the internal JobHandler parallel system is performed, a cluster test must be added setting, in XML block, the node <internalParallel> to True.
  • 6. If the change modifies or adds a requirement or a requirement based test case, the Change Control Board's Chair or designee also needs to approve the change. The requirements and the requirements test shall be in sync.
  • 7. The merge request must reference an issue. If the issue is closed, the issue close checklist shall be done.
  • 8. If an analytic test is changed/added is the the analytic documentation updated/added?
  • 9. If any test used as a basis for documentation examples (currently found in raven/tests/framework/user_guide and raven/docs/workshop) have been changed, the associated documentation must be reviewed and assured the text matches the example.

@PaulTalbot-INL PaulTalbot-INL changed the title Plotting OutStreams as RAVEN entity Oct 2, 2020
from .FilePrint import FilePrint
from .GeneralPlot import GeneralPlot
# from .DataMining import DataMining
# from .VDCComparison import VDCComparison
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are placeholders for the future; they can be removed if desired. Same with later on in this file.

@PaulTalbot-INL
Copy link
Collaborator Author

Because of that "version 5.7.0" pyomo issue, adding the HERON submodule update as well. The PR I wanted has been merged, anyway.

@PaulTalbot-INL
Copy link
Collaborator Author

I didn't consider the possibility of a PIP-only install with HERON; I've added it to HERON feature requests: idaholab/HERON/issues/33

framework/OutStreams/FilePrint.py Show resolved Hide resolved
'Print': FilePrint,
'Plot': GeneralPlot,
# 'DataMining': DataMining,
# 'VDCComparison': VDCComparison,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In my opinion the specializations of the Plots/Prints should be under Plot/Print (similarly to External Model/type or Code, CodeInterfaces)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

placeholder for discussion

Copy link
Collaborator Author

@PaulTalbot-INL PaulTalbot-INL Oct 2, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm noticing immediately that there would be a big benefit for a base class for Plot, although I think the Entity approach is cleaner. Maybe in the future:

<OutStreams>
    <Print>
        <MyCustomPrint>
          <... options ...>
        </MyCustomPrint>
    </Print>
</OutStreams>

although there's a couple things I don't love about this:

  • It forces an OutStream to be only a Print or a Plot (I can imagine cases where both make sense)
  • It is regressing towards the approach in the listing class=OutStream, type=Print, subType=MyPrint instead of class=OutStream type=MyPrint
  • We have to modify all existing RAVEN inputs if we add a subspot under for , or some fancy checking to see if we're dealing with a special type or the generic type.

The other two options I see are the way I hinted at here

<OutStreams>
    <MyCustomPrint>
        <... options ...>
    </MyCustomPrint>
</OutStreams>

or using the subType approach from the ROMs, that I think we don't like much.

Definitely a good discussion to have when we start designing the first new entries.

framework/OutStreams/GeneralPlot.py Outdated Show resolved Hide resolved
framework/utils/InputData.py Outdated Show resolved Hide resolved
tests/framework/test_output.xml Show resolved Hide resolved
tests/framework/tests Show resolved Hide resolved
@alfoa
Copy link
Collaborator

alfoa commented Oct 2, 2020

Minor changes

@alfoa
Copy link
Collaborator

alfoa commented Oct 2, 2020

is the HERON update done on purpose? or just a mistake?

@alfoa
Copy link
Collaborator

alfoa commented Oct 2, 2020

is the HERON update done on purpose? or just a mistake?

okay. it is done on purpose. Asked @PaulTalbot-INL

Copy link
Collaborator

@alfoa alfoa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comments addressed

@alfoa
Copy link
Collaborator

alfoa commented Oct 3, 2020

PR is approved to be merged.

@alfoa alfoa merged commit 1ce4703 into idaholab:devel Oct 3, 2020
@alfoa alfoa deleted the plotting branch October 3, 2020 16:11
@alfoa alfoa mentioned this pull request Oct 3, 2020
10 tasks
@alfoa alfoa added the RAVENv2.1 All tasks and defects that will go in RAVEN v2.1 label Oct 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
RAVENv2.1 All tasks and defects that will go in RAVEN v2.1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[TASK] OutStreams as extensible Entity
2 participants